﻿using System;
using System.Collections.Generic;
using System.Text;

namespace SuperX.Common.Scheduler
{
    // 
    public class SchedulerMsg : IComparable<SchedulerMsg>
    {
        // 
        public IScheduler Dispatcher { get; set; }

        // 
        public SchedulerValue DispatchValue { get; set; }

        // 
        public SchedulerMsg(IScheduler dispatcher, SchedulerValue dispatchValue)
        {
            this.Dispatcher = dispatcher;
            this.DispatchValue = dispatchValue;
        }

        // 
        public int CompareTo(SchedulerMsg other)
        {
            return this.DispatchValue.TimeStamp.CompareTo(other.DispatchValue.TimeStamp);
        }
    }
}
